package com.cty.config;

import com.zhenzi.sms.ZhenziSmsClient;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
public class SmsConfig {
    @Value("${sms.apiUrl}")
    private String apiUrl;
    @Value("${sms.appId}")
    private  String appId;
    @Value("${sms.appSecret}")
    private  String appSecret;
    @Bean
    public ZhenziSmsClient zhenziSmsClient(){
        return  new ZhenziSmsClient(apiUrl, appId, appSecret);
    }
}
